<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>v-on的修饰符</title>
</head>

<body>
    <div id="app">
        div格子
        <!--1 .stop修饰符的使用-->
        <div @click="divClick">
            <button @click="btnClick">按钮</button>
            <button @click.stop="btnClick">按钮</button>
        </div>

        <!--2 .prevent修饰符的使用-->
        <form action="baidu">
            <input type="submit" value="提交" @click="submitClick">
        </form>
    </div>
            
    <script src="./js/vue.min.js"></script>
    <script>

        const app = new Vue({
            el: '#app',
            data: {
                message: "你好啊"
            },
            methods: {
                divClick() {
                    console.log('点击div');
                },
                btnClick() {
                    console.log('点击按钮btn');
                },
                submit() {
                    
                }
                
            }
        })
    </script>
</body>

</html>